/*
 * File: sign.c
 *
 * MATLAB Coder version            : 24.2
 * C/C++ source code generated on  : 2025-05-29 15:13:57
 */

/* Include Files */
#include "sign.h"
#include "rt_nonfinite.h"
#include "rt_nonfinite.h"

/* Function Definitions */
/*
 * Arguments    : double x[102400]
 * Return Type  : void
 */
void b_sign(double x[102400])
{
  int k;
  for (k = 0; k < 102400; k++) {
    if (rtIsNaN(x[k])) {
      x[k] = rtNaN;
    } else if (x[k] < 0.0) {
      x[k] = -1.0;
    } else {
      x[k] = (x[k] > 0.0);
    }
  }
}

/*
 * File trailer for sign.c
 *
 * [EOF]
 */
